<?php
abstract class Controller {
    protected $view;
    function __construct() {

        $this->view = new STE;
        $this->view->setDir(SF_ROOT_DIR.'/tpls');

        if (!isset($_SERVER['REQUEST_METHOD'])) {//cli
            $this->cli();
        } else if ($_SERVER['REQUEST_METHOD']=='GET') {//http post
            $this->get();
        } else if ($_SERVER['REQUEST_METHOD']=='POST') {//http post
            $this->post();
        } else if ($_SERVER['REQUEST_METHOD']=='HEAD') {//http head
            $this->head();
        }
    }
    function cli() {
    }
    function get() {
    }
    function post() {
    }
    function head() {
    }

}
